<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        .red {
            color: red;
        }
        .purple {
            color: purple;
        }
        .yellow {
            color: yellow;
        }
    </style>
</head>
<body>
    <h1 class="red">测试class属性的作用</h1>
    <h1 class="purple">测试class属性的作用</h1>
    <h1 class="yellow">测试class属性的作用</h1>
</body>
</html>